#include "pages.h"

#include <QtCore>
////#include <QtScript>

T_Page1::T_Page1()
{
}

void T_Page1::op_01(QString a_msg)
{
	qDebug() << "T_Page1::op_01()" << a_msg;

#if 0x0
	QScriptEngine v_engine;

	QString fileName = ":/jslib/json2.js";
	QFile scriptFile(fileName);
	if (!scriptFile.open(QIODevice::ReadOnly))
	{
		// handle error
		qDebug() << "Read Error:" << fileName;
		return;
	}
	QTextStream stream(&scriptFile);
	stream.setCodec(QTextCodec::codecForName("UTF-8"));
	QString contents = stream.readAll();
	scriptFile.close();
	v_engine.evaluate(contents, fileName);

	QScriptValue v_three = v_engine.evaluate("1 + 2");
	qDebug() << v_three.toString();
	QScriptValue v_1 = v_engine.evaluate("({x:11, y:22})");
	qDebug() << v_1.toString();
	QScriptValue v_2 = v_engine.evaluate("{x:11, y:22}");
	qDebug() << v_2.toString();
#endif
 }
